using System;
using System.Collections.Generic;
using System.Text;
using Calc.Execution;

namespace Calc.Operations.Functions
{
	public class Atan : Function
	{
		public const string NAME = "atan";

		public Atan()
			: base(NAME)
		{
			_variables.Add(new Variable("x"));
		}

		public override double GetValue(ExecutionContext context)
		{
			double x = context.GetVariable("x");

			return (double)Math.Atan((double)x);
		}
	}
}
